package com.winit.need.service;

import com.alibaba.fastjson.JSONArray;
import com.winit.common.base.bean.ExecuteResult;
import com.winit.need.model.Need;

import java.util.List;
import java.util.Map;

public interface NeedService {
    Need selectByPrimaryKey(String reqId);
    ExecuteResult<Need> saveNeed(Need need);
    ExecuteResult<Need> updateNeed(Need need);
    ExecuteResult<List<Need>> getNeedList(String id,Boolean isPage,String status,String proposerAccount,String source,String keyword,String pdmAccount,String pdmGroup,Long startDate,Boolean isOnline,String acceptAccount,String appointAcceptAccount,String myAccount);
    ExecuteResult<Map<String,Long>> getStatusCount(JSONArray statusList,Long starDate,Long endDate,String proposerAccount,String proposerDepartment,String productGroup,String pdmAccount,String source);
    ExecuteResult updateNeedStar(String id, String star);

    ExecuteResult getAcceptanceProbability(String type,Long starDate,Long endDate,String proposerAccount,String proposerDepartment,String productGroup,String pdmAccount,String source);
    void timingUpdate();

    void timingUpdateClosed();

    ExecuteResult<List> getNeedPlan(String needId);

    ExecuteResult deleteNeed(String id);
    ExecuteResult getAcceptAccountAndStatus(String acceptAccount,String status);
}
